Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test: Added PostUpgradeArb #1512

Closed
wants to merge 2 commits into from
Closed

Conversation

dansteren
Copy link
Contributor

@dansteren dansteren commented Dec 14, 2023

Builds off of #1492 to add PostUpgrade tests to our canister methods.

Caution

Change the base of this brach to main before merging.

Closes #1497

@dansteren dansteren linked an issue Dec 29, 2023 that may be closed by this pull request
4 tasks
name: `init method`,
test: async () => {
const actor = getActor('./tests/post_upgrade_method/test');
const result = await actor.getPostDeployValues();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this needs to be redone. The init method tests should be completely separate from the post upgrade tests. These tests should be almost identical to the actual init method tests, using the same global variables. We do not want the global variables for testing init and post_upgrade to be the same, otherwise you don't have a guarantee that a deploy occurred.


runPropTests(CanisterArb(CanisterConfigArb));

function generateGetPostDeployValuesCanisterMethod(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this how we did the getInitValues in the init method test?

@bdemann bdemann deleted the branch 1471_init_method_arb January 15, 2024 20:46
@bdemann bdemann closed this Jan 15, 2024
@bdemann bdemann mentioned this pull request Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

post_upgrade
3 participants